<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="f" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<%--<c:set var="ctx" value="${param.name}"/>--%>
<%--<c:set var="name" value="${param.name.concat('.totalPage')}"/>--%>
<!-- 分页处理 -->
<table width='100%' align='center' style='font-size: 13px;' class="yahoo">
    <%--用户--%>
    <c:if test="${param.name=='users'}">
        <tr>
            <td
                    style='COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; TEXT-DECORATION: none'>
                总页数${users.totalPage}&nbsp;&nbsp;总记录条数${users.totalCount}
                <c:choose>
                    <%--             如果只有一页--%>
                    <c:when test="${users.totalPage==1}">
                        <span class='disabled'>上一页</span>
                        <span class='current'>1</span>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				如果是第一页--%>
                    <c:when test="${users.currentPage==1}">
                        <span class='disabled'>上一页</span>
                        <c:forEach begin="1" end="${users.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${users.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${users.currentPage+1})">下一页</a></span>
                    </c:when>
                    <%--				如果是最后一页--%>
                    <c:when test="${users.currentPage==users.totalPage}">
					<span class='current'>
						<a href='#' onclick="toPage(${users.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${users.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${users.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				普通情况--%>
                    <c:otherwise>
                        <span class='current'><a href='#' onclick="toPage(${users.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${users.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${users.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${users.currentPage+1})">下一页</a></span>
                    </c:otherwise>
                </c:choose> &nbsp;跳转到&nbsp;&nbsp;
                <input type='text'
                       style='text-align: center; BORDER-RIGHT: #aaaadd 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #aaaadd 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 2px; MARGIN: 2px; BORDER-LEFT: #aaaadd 1px solid; COLOR: #000099; PADDING-TOP: 2px; BORDER-BOTTOM: #aaaadd 1px solid; TEXT-DECORATION: none'
                       size='2' id='pager_jump_page_size'/> &nbsp;
                <input type='button'
                       style='text-align: center; BORDER-RIGHT: #dedfde 1px solid; PADDING-RIGHT: 6px; BACKGROUND-POSITION: 50% bottom; BORDER-TOP: #dedfde 1px solid; PADDING-LEFT: 6px; PADDING-BOTTOM: 2px; BORDER-LEFT: #dedfde 1px solid; COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; BORDER-BOTTOM: #dedfde 1px solid; TEXT-DECORATION: none'
                       value='确定' id='pager_jump_btn' onclick="pagerJump()"/>
            </td>
        </tr>
    </c:if>
    <%--部门--%>
    <c:if test="${param.name=='depts'}">
        <tr>
            <td
                    style='COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; TEXT-DECORATION: none'>
                总页数${depts.totalPage}&nbsp;&nbsp;总记录条数${depts.totalCount}
                <c:choose>
                    <%--             如果只有一页--%>
                    <c:when test="${depts.totalPage==1}">
                        <span class='disabled'>上一页</span>
                        <span class='current'>1</span>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				如果是第一页--%>
                    <c:when test="${depts.currentPage==1}">
                        <span class='disabled'>上一页</span>
                        <c:forEach begin="1" end="${depts.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${depts.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${depts.currentPage+1})">下一页</a></span>
                    </c:when>
                    <%--				如果是最后一页--%>
                    <c:when test="${depts.currentPage==depts.totalPage}">
					<span class='current'>
						<a href='#' onclick="toPage(${depts.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${depts.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${depts.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				普通情况--%>
                    <c:otherwise>
                        <span class='current'><a href='#' onclick="toPage(${depts.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${depts.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${depts.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${depts.currentPage+1})">下一页</a></span>
                    </c:otherwise>
                </c:choose> &nbsp;跳转到&nbsp;&nbsp;
                <input type='text'
                       style='text-align: center; BORDER-RIGHT: #aaaadd 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #aaaadd 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 2px; MARGIN: 2px; BORDER-LEFT: #aaaadd 1px solid; COLOR: #000099; PADDING-TOP: 2px; BORDER-BOTTOM: #aaaadd 1px solid; TEXT-DECORATION: none'
                       size='2' id='pager_jump_page_size'/> &nbsp;
                <input type='button'
                       style='text-align: center; BORDER-RIGHT: #dedfde 1px solid; PADDING-RIGHT: 6px; BACKGROUND-POSITION: 50% bottom; BORDER-TOP: #dedfde 1px solid; PADDING-LEFT: 6px; PADDING-BOTTOM: 2px; BORDER-LEFT: #dedfde 1px solid; COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; BORDER-BOTTOM: #dedfde 1px solid; TEXT-DECORATION: none'
                       value='确定' id='pager_jump_btn' onclick="pagerJump()"/>
            </td>
        </tr>
    </c:if>
    <%--	职位--%>
    <c:if test="${param.name=='jobs'}">
        <tr>
            <td
                    style='COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; TEXT-DECORATION: none'>
                总页数${jobs.totalPage}&nbsp;&nbsp;总记录条数${jobs.totalCount}
                <c:choose>
                    <%--             如果只有一页--%>
                    <c:when test="${jobs.totalPage==1}">
                        <span class='disabled'>上一页</span>
                        <span class='current'>1</span>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				如果是第一页--%>
                    <c:when test="${jobs.currentPage==1}">
                        <span class='disabled'>上一页</span>
                        <c:forEach begin="1" end="${jobs.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${jobs.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${jobs.currentPage+1})">下一页</a></span>
                    </c:when>
                    <%--				如果是最后一页--%>
                    <c:when test="${jobs.currentPage==jobs.totalPage}">
					<span class='current'>
						<a href='#' onclick="toPage(${jobs.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${jobs.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${jobs.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				普通情况--%>
                    <c:otherwise>
                        <span class='current'><a href='#' onclick="toPage(${jobs.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${jobs.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${jobs.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${jobs.currentPage+1})">下一页</a></span>
                    </c:otherwise>
                </c:choose> &nbsp;跳转到&nbsp;&nbsp;
                <input type='text'
                       style='text-align: center; BORDER-RIGHT: #aaaadd 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #aaaadd 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 2px; MARGIN: 2px; BORDER-LEFT: #aaaadd 1px solid; COLOR: #000099; PADDING-TOP: 2px; BORDER-BOTTOM: #aaaadd 1px solid; TEXT-DECORATION: none'
                       size='2' id='pager_jump_page_size'/> &nbsp;
                <input type='button'
                       style='text-align: center; BORDER-RIGHT: #dedfde 1px solid; PADDING-RIGHT: 6px; BACKGROUND-POSITION: 50% bottom; BORDER-TOP: #dedfde 1px solid; PADDING-LEFT: 6px; PADDING-BOTTOM: 2px; BORDER-LEFT: #dedfde 1px solid; COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; BORDER-BOTTOM: #dedfde 1px solid; TEXT-DECORATION: none'
                       value='确定' id='pager_jump_btn' onclick="pagerJump()"/>
            </td>
        </tr>
    </c:if>
    <%--	员工--%>
    <c:if test="${param.name=='employees'}">
        <tr>
            <td
                    style='COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; TEXT-DECORATION: none'>
                总页数${employees.totalPage}&nbsp;&nbsp;总记录条数${employees.totalCount}
                <c:choose>
                    <%--             如果只有一页--%>
                    <c:when test="${employees.totalPage==1}">
                        <span class='disabled'>上一页</span>
                        <span class='current'>1</span>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				如果是第一页--%>
                    <c:when test="${employees.currentPage==1}">
                        <span class='disabled'>上一页</span>
                        <c:forEach begin="1" end="${employees.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${employees.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${employees.currentPage+1})">下一页</a></span>
                    </c:when>
                    <%--				如果是最后一页--%>
                    <c:when test="${employees.currentPage==employees.totalPage}">
					<span class='current'>
						<a href='#' onclick="toPage(${employees.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${employees.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${employees.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				普通情况--%>
                    <c:otherwise>
                        <span class='current'><a href='#' onclick="toPage(${employees.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${employees.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${employees.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${employees.currentPage+1})">下一页</a></span>
                    </c:otherwise>
                </c:choose> &nbsp;跳转到&nbsp;&nbsp;
                <input type='text'
                       style='text-align: center; BORDER-RIGHT: #aaaadd 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #aaaadd 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 2px; MARGIN: 2px; BORDER-LEFT: #aaaadd 1px solid; COLOR: #000099; PADDING-TOP: 2px; BORDER-BOTTOM: #aaaadd 1px solid; TEXT-DECORATION: none'
                       size='2' id='pager_jump_page_size'/> &nbsp;
                <input type='button'
                       style='text-align: center; BORDER-RIGHT: #dedfde 1px solid; PADDING-RIGHT: 6px; BACKGROUND-POSITION: 50% bottom; BORDER-TOP: #dedfde 1px solid; PADDING-LEFT: 6px; PADDING-BOTTOM: 2px; BORDER-LEFT: #dedfde 1px solid; COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; BORDER-BOTTOM: #dedfde 1px solid; TEXT-DECORATION: none'
                       value='确定' id='pager_jump_btn' onclick="pagerJump()"/>
            </td>
        </tr>
    </c:if>
    <%--	公告--%>
    <c:if test="${param.name=='annos'}">
        <tr>
            <td
                    style='COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; TEXT-DECORATION: none'>
                总页数${annos.totalPage}&nbsp;&nbsp;总记录条数${annos.totalCount}
                <c:choose>
                    <%--             如果只有一页--%>
                    <c:when test="${annos.totalPage==1}">
                        <span class='disabled'>上一页</span>
                        <span class='current'>1</span>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				如果是第一页--%>
                    <c:when test="${annos.currentPage==1}">
                        <span class='disabled'>上一页</span>
                        <c:forEach begin="1" end="${annos.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${annos.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${annos.currentPage+1})">下一页</a></span>
                    </c:when>
                    <%--				如果是最后一页--%>
                    <c:when test="${annos.currentPage==annos.totalPage}">
					<span class='current'>
						<a href='#' onclick="toPage(${annos.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${annos.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${annos.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				普通情况--%>
                    <c:otherwise>
                        <span class='current'><a href='#' onclick="toPage(${annos.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${annos.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${annos.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${annos.currentPage+1})">下一页</a></span>
                    </c:otherwise>
                </c:choose> &nbsp;跳转到&nbsp;&nbsp;
                <input type='text'
                       style='text-align: center; BORDER-RIGHT: #aaaadd 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #aaaadd 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 2px; MARGIN: 2px; BORDER-LEFT: #aaaadd 1px solid; COLOR: #000099; PADDING-TOP: 2px; BORDER-BOTTOM: #aaaadd 1px solid; TEXT-DECORATION: none'
                       size='2' id='pager_jump_page_size'/> &nbsp;
                <input type='button'
                       style='text-align: center; BORDER-RIGHT: #dedfde 1px solid; PADDING-RIGHT: 6px; BACKGROUND-POSITION: 50% bottom; BORDER-TOP: #dedfde 1px solid; PADDING-LEFT: 6px; PADDING-BOTTOM: 2px; BORDER-LEFT: #dedfde 1px solid; COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; BORDER-BOTTOM: #dedfde 1px solid; TEXT-DECORATION: none'
                       value='确定' id='pager_jump_btn' onclick="pagerJump()"/>
            </td>
        </tr>
    </c:if>
    <%--	文件--%>
    <c:if test="${param.name=='documents'}">
        <tr>
            <td
                    style='COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; TEXT-DECORATION: none'>
                总页数${documents.totalPage}&nbsp;&nbsp;总记录条数${documents.totalCount}
                <c:choose>
                    <%--             如果只有一页--%>
                    <c:when test="${documents.totalPage==1}">
                        <span class='disabled'>上一页</span>
                        <span class='current'>1</span>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				如果是第一页--%>
                    <c:when test="${documents.currentPage==1}">
                        <span class='disabled'>上一页</span>
                        <c:forEach begin="1" end="${documents.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${documents.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${documents.currentPage+1})">下一页</a></span>
                    </c:when>
                    <%--				如果是最后一页--%>
                    <c:when test="${documents.currentPage==documents.totalPage}">
					<span class='current'>
						<a href='#' onclick="toPage(${documents.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${documents.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${documents.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='disabled'>下一页</span>
                    </c:when>
                    <%--				普通情况--%>
                    <c:otherwise>
                        <span class='current'><a href='#' onclick="toPage(${documents.currentPage-1})">上一页</a></span>
                        <c:forEach begin="1" end="${documents.totalPage}" var="i">
                            <c:choose>
                                <c:when test="${documents.currentPage==i}">
                                    <span class='current'>${i}</span>
                                </c:when>
                                <c:otherwise>
                                    <a href='#' onclick="toPage(${i})">${i}</a>
                                </c:otherwise>
                            </c:choose>
                        </c:forEach>
                        <span class='current'><a href='#'
                                                 onclick="toPage(${documents.currentPage+1})">下一页</a></span>
                    </c:otherwise>
                </c:choose> &nbsp;跳转到&nbsp;&nbsp;
                <input type='text'
                       style='text-align: center; BORDER-RIGHT: #aaaadd 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #aaaadd 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 2px; MARGIN: 2px; BORDER-LEFT: #aaaadd 1px solid; COLOR: #000099; PADDING-TOP: 2px; BORDER-BOTTOM: #aaaadd 1px solid; TEXT-DECORATION: none'
                       size='2' id='pager_jump_page_size'/> &nbsp;
                <input type='button'
                       style='text-align: center; BORDER-RIGHT: #dedfde 1px solid; PADDING-RIGHT: 6px; BACKGROUND-POSITION: 50% bottom; BORDER-TOP: #dedfde 1px solid; PADDING-LEFT: 6px; PADDING-BOTTOM: 2px; BORDER-LEFT: #dedfde 1px solid; COLOR: #0061de; MARGIN-RIGHT: 3px; PADDING-TOP: 2px; BORDER-BOTTOM: #dedfde 1px solid; TEXT-DECORATION: none'
                       value='确定' id='pager_jump_btn' onclick="pagerJump()"/>
            </td>
        </tr>
    </c:if>
</table>